/**
  ETFRoot project, Anyang Normal University && IMP-CAS
  \class ETFTaTrackManager
  \brief a manager class holding the fitted tracks and trackers. NOTE that this
  is a singleton class. The class is dedicated for P.Ma-style cosmic-ray tests
  \author SUN Yazhou, asia.rabbit@163.com
  \since 2022-04-26
  \date 2022-04-26 last modified
  \attention
  changelog
  <table>
  <tr>  <th>Date         <th>Author      <th>Description                   </tr>
  <tr>  <td>2022-04-26   <td>Asia Sun    <td>file created                  </tr>
  </table>

  \copyright Copyright (c) 2021 Anyang Normal U. && IMP-CAS with LGPLv3 LICENSE
*/

#ifndef ETFTaTrackManager_h
#define ETFTaTrackManager_h

class ETFTaTracker;

#include "ETFVTrackManager.h"

class ETFTaTrackManager : public ETFVTrackManager{
public:
  static ETFTaTrackManager *Instance();
  virtual ~ETFTaTrackManager();

  virtual ETFTaTracker *GetPreTaTracker() const{ return fPreTaTracker; }
  virtual ETFTaTracker *GetPostTaTracker() const{ return fPostTaTracker; }
  virtual ETFTaTracker *GetTaTracker() const{ return fTaTracker; }

  virtual void Draw(); ///< draw the tracks
  virtual void Write(); ///< write all the tracks to file
  virtual void Map(); ///< do the overall tracking
  virtual void Map3D(); ///< do the overall 3D tracking
  virtual void Register(); ///< register tracks to main TTree
  virtual void Reset(); ///< reset for next event
  virtual void Print();
  virtual void SetDebug(bool opt = true);

  ClassDef(ETFTaTrackManager, 0);

protected:
  ETFTaTrackManager();

  static ETFTaTrackManager *fInstance;
  ETFTaTracker *fPreTaTracker; ///< the first 2 DCs
  ETFTaTracker *fPostTaTracker; ///< the last 2 DCs
  ETFTaTracker *fTaTracker; ///< containing all the 4 DCs
};

#endif
